Optimal. Leaf size=29 \[ \frac{1}{5} i \sin ^5(x)-\frac{1}{3} i \sin ^3(x)-\frac{1}{5} \cos ^5(x) \]
[Out]
________________________________________________________________________________________
Rubi [A] time = 0.160735, antiderivative size = 29, normalized size of antiderivative = 1., number of steps used = 9, number of rules used = 7, integrand size = 13, \(\frac{\text{number of rules}}{\text{integrand size}}\) = 0.538, Rules used = {3518, 3108, 3107, 2565, 30, 2564, 14} \[ \frac{1}{5} i \sin ^5(x)-\frac{1}{3} i \sin ^3(x)-\frac{1}{5} \cos ^5(x) \]
Antiderivative was successfully verified.
[In]
[Out]
Rule 3518
Rule 3108
Rule 3107
Rule 2565
Rule 30
Rule 2564
Rule 14
Rubi steps
\begin{align*} \int \frac{\cos ^3(x)}{i+\cot (x)} \, dx &=-\int \frac{\cos ^3(x) \sin (x)}{-\cos (x)-i \sin (x)} \, dx\\ &=i \int \cos ^3(x) (-i \cos (x)-\sin (x)) \sin (x) \, dx\\ &=i \int \left (-i \cos ^4(x) \sin (x)-\cos ^3(x) \sin ^2(x)\right ) \, dx\\ &=-\left (i \int \cos ^3(x) \sin ^2(x) \, dx\right )+\int \cos ^4(x) \sin (x) \, dx\\ &=-\left (i \operatorname{Subst}\left (\int x^2 \left (1-x^2\right ) \, dx,x,\sin (x)\right )\right )-\operatorname{Subst}\left (\int x^4 \, dx,x,\cos (x)\right )\\ &=-\frac{1}{5} \cos ^5(x)-i \operatorname{Subst}\left (\int \left (x^2-x^4\right ) \, dx,x,\sin (x)\right )\\ &=-\frac{1}{5} \cos ^5(x)-\frac{1}{3} i \sin ^3(x)+\frac{1}{5} i \sin ^5(x)\\ \end{align*}
Mathematica [A] time = 0.0927364, size = 42, normalized size = 1.45 \[ -\frac{\csc (x) (i (10 \sin (2 x)+\sin (4 x))+20 \cos (2 x)+4 \cos (4 x))}{120 (\cot (x)+i)} \]
Antiderivative was successfully verified.
[In]
[Out]
________________________________________________________________________________________
Maple [B] time = 0.046, size = 93, normalized size = 3.2 \begin{align*}{{\frac{i}{6}} \left ( \tan \left ({\frac{x}{2}} \right ) +i \right ) ^{-3}}-{{\frac{3\,i}{8}} \left ( \tan \left ({\frac{x}{2}} \right ) +i \right ) ^{-1}}-{\frac{1}{4} \left ( \tan \left ({\frac{x}{2}} \right ) +i \right ) ^{-2}}-{{\frac{4\,i}{3}} \left ( \tan \left ({\frac{x}{2}} \right ) -i \right ) ^{-3}}+{{\frac{3\,i}{8}} \left ( \tan \left ({\frac{x}{2}} \right ) -i \right ) ^{-1}}+{{\frac{2\,i}{5}} \left ( \tan \left ({\frac{x}{2}} \right ) -i \right ) ^{-5}}+ \left ( \tan \left ({\frac{x}{2}} \right ) -i \right ) ^{-4}- \left ( \tan \left ({\frac{x}{2}} \right ) -i \right ) ^{-2} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Maxima [F(-2)] time = 0., size = 0, normalized size = 0. \begin{align*} \text{Exception raised: RuntimeError} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Fricas [B] time = 1.62988, size = 170, normalized size = 5.86 \begin{align*} -\frac{1}{240} \,{\left (5 \,{\left (e^{\left (6 i \, x\right )} + 9 \, e^{\left (4 i \, x\right )} - 9 \, e^{\left (2 i \, x\right )} - 1\right )} e^{\left (2 i \, x\right )} - 15 \, e^{\left (6 i \, x\right )} + 45 \, e^{\left (4 i \, x\right )} + 15 \, e^{\left (2 i \, x\right )} + 3\right )} e^{\left (-5 i \, x\right )} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Sympy [A] time = 0.508481, size = 36, normalized size = 1.24 \begin{align*} - \frac{e^{3 i x}}{48} - \frac{e^{i x}}{8} - \frac{e^{- 3 i x}}{24} - \frac{e^{- 5 i x}}{80} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]
________________________________________________________________________________________
Giac [B] time = 1.22324, size = 93, normalized size = 3.21 \begin{align*} -\frac{9 i \, \tan \left (\frac{1}{2} \, x\right )^{2} - 12 \, \tan \left (\frac{1}{2} \, x\right ) - 7 i}{24 \,{\left (\tan \left (\frac{1}{2} \, x\right ) + i\right )}^{3}} - \frac{-45 i \, \tan \left (\frac{1}{2} \, x\right )^{4} - 60 \, \tan \left (\frac{1}{2} \, x\right )^{3} + 70 i \, \tan \left (\frac{1}{2} \, x\right )^{2} + 20 \, \tan \left (\frac{1}{2} \, x\right ) - 13 i}{120 \,{\left (\tan \left (\frac{1}{2} \, x\right ) - i\right )}^{5}} \end{align*}
Verification of antiderivative is not currently implemented for this CAS.
[In]
[Out]